package main

import (
	"errors"

	"github.com/pkg/errors"
)

func main() {
	err := service()
}

func service() error {
	err := biz()
	return errors.WithMessage(err, "this is service")
}

func biz() error {
	err := dao()
	return errors.WithMessage(err, "this is biz")
}

func dao() error {
	err := errors.New("dao err")
	return errors.Wrap(err, "this is dao")
}
